package com.ghy.www.my.servicegoup.consumer.javaconfig;

import com.ghy.www.api.IService1;
import org.apache.dubbo.config.annotation.DubboReference;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

@Configuration
public class JavaConfigDubbo {
    @DubboReference(group = "IServer1_A")
    private IService1 service1;

    @DubboReference(group = "IServer1_B")
    private IService1 service2;

    @Bean("a")
    public IService1 getService1() {
        return service1;
    }

    @Bean("b")
    public IService1 getService2() {
        return service2;
    }
}
